<?php

class ads extends stwidgets {

    function ads() {
        $this->WP_Widget(false, $name = 'Ads Partner');
    }

    function widget($args, $instance) {
        $ads_link_to = $instance['ads_link_to'];
        $ads_url = $instance['ads_url'];
        $ads_width = $instance['ads_width'];
        ?>
        <style type="text/css">
            .image_fl{float:left;}
        </style>
        <div class="image_fl">
            <a href="<?php echo $ads_link_to ?>"><img src="<?php echo $ads_url ?>" style="width: <?php echo $ads_width ?>px; height: 75px;"></a>   
        </div>

   <?php }

    function form($instance) {
        ?>
        <p>
            <label for="">Ads image url</label>
            <input type="text" name="ads_url" class="widefat" value="<?php echo $instance['ads_url'] ?>">
        </p>
        <p
            <label for="">Width</label>
            <input type="text" name="ads_width" class="widefat" value="<?php echo $instance['ads_width'] ?>">
        </p>
        <p
            <label for="">Link to</label>
            <input type="text" name="ads_link_to" class="widefat" value="<?php echo $instance['ads_link_to'] ?>">
        </p>
        <?php
    }

}